package com.zatech.cgnci.project.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * <p>
 * 币种汇率表
 * </p>
 *
 * @author Generator
 * @since 2024-12-17
 */
@Getter
@Setter
@Accessors(chain = true)
@TableName("cgnci_exchange_rate")
@ApiModel(value = "CgnciExchangeRateDO对象", description = "币种汇率表")
public class CgnciExchangeRateDO implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("汇率ID")
    @TableId(value = "rate_id", type = IdType.ASSIGN_ID)
    private Long rateId;

    @ApiModelProperty("业务ID")
    private Long businessId;

    @ApiModelProperty("唯一键")
    private String rowKey;

    @ApiModelProperty("币种(CNY-人民币,USD-美元,HKD-港币,EUR-欧元),码表值:C00003")
    private String currency;

    @ApiModelProperty("约定方式(1-约定频率,2-约定汇率,3-约定日期),码表值:agreementMethod")
    private String agreementMethod;

    @ApiModelProperty("约定频率--(1-账期月),码表值:agreementFrequencyMonth")
    private String agreementFrequencyMonth;

    @ApiModelProperty("约定频率--(1-月初,2-月末),码表值:agreementFrequencyPeriod")
    private String agreementFrequencyPeriod;

    @ApiModelProperty("约定汇率")
    private BigDecimal agreementRate;

    @ApiModelProperty("约定日期")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT-8")
    private Date agreementDate;

    @ApiModelProperty("创建时间")
    private Date createTime;

    @ApiModelProperty("创建人")
    private String createUser;

    @ApiModelProperty("更新时间")
    @TableField(update = "now()")
    private Date updateTime;

    @ApiModelProperty("更新人")
    private String updateUser;


}
